Integrand size = 33, antiderivative size = 427 \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{(a+b x)^4} \, dx=-\frac {2 B^2 d^2 n^2 (c+d x)}{(b c-a d)^3 (a+b x)}+\frac {b B^2 d n^2 (c+d x)^2}{2 (b c-a d)^3 (a+b x)^2}-\frac {2 b^2 B^2 n^2 (c+d x)^3}{27 (b c-a d)^3 (a+b x)^3}-\frac {2 B d^2 n (c+d x) \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )}{(b c-a d)^3 (a+b x)}+\frac {b B d n (c+d x)^2 \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )}{(b c-a d)^3 (a+b x)^2}-\frac {2 b^2 B n (c+d x)^3 \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )}{9 (b c-a d)^3 (a+b x)^3}-\frac {d^2 (c+d x) \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{(b c-a d)^3 (a+b x)}+\frac {b d (c+d x)^2 \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{(b c-a d)^3 (a+b x)^2}-\frac {b^2 (c+d x)^3 \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{3 (b c-a d)^3 (a+b x)^3} \]
-2*B^2*d^2*n^2*(d*x+c)/(-a*d+b*c)^3/(b*x+a)+1/2*b*B^2*d*n^2*(d*x+c)^2/(-a* d+b*c)^3/(b*x+a)^2-2/27*b^2*B^2*n^2*(d*x+c)^3/(-a*d+b*c)^3/(b*x+a)^3-2*B*d ^2*n*(d*x+c)*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))/(-a*d+b*c)^3/(b*x+a)+b*B*d* n*(d*x+c)^2*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))/(-a*d+b*c)^3/(b*x+a)^2-2/9*b ^2*B*n*(d*x+c)^3*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))/(-a*d+b*c)^3/(b*x+a)^3- d^2*(d*x+c)*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))^2/(-a*d+b*c)^3/(b*x+a)+b*d*( d*x+c)^2*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))^2/(-a*d+b*c)^3/(b*x+a)^2-1/3*b^ 2*(d*x+c)^3*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))^2/(-a*d+b*c)^3/(b*x+a)^3
Time = 0.47 (sec) , antiderivative size = 432, normalized size of antiderivative = 1.01 \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{(a+b x)^4} \, dx=\frac {18 B^2 d^3 n^2 (a+b x)^3 \log ^2(a+b x)+18 B^2 d^3 n^2 (a+b x)^3 \log ^2(c+d x)+6 B d^3 n (a+b x)^3 \log (c+d x) \left (6 A+11 B n+6 B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )-6 B d^3 n (a+b x)^3 \log (a+b x) \left (6 A+11 B n+6 B n \log (c+d x)+6 B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )-(b c-a d) \left (18 A^2 (b c-a d)^2+6 A B n \left (11 a^2 d^2+a b d (-7 c+15 d x)+b^2 \left (2 c^2-3 c d x+6 d^2 x^2\right )\right )+B^2 n^2 \left (85 a^2 d^2+a b d (-23 c+147 d x)+b^2 \left (4 c^2-15 c d x+66 d^2 x^2\right )\right )+6 B \left (6 A (b c-a d)^2+B n \left (11 a^2 d^2+a b d (-7 c+15 d x)+b^2 \left (2 c^2-3 c d x+6 d^2 x^2\right )\right )\right ) \log \left (e (a+b x)^n (c+d x)^{-n}\right )+18 B^2 (b c-a d)^2 \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right )\right )}{54 b (b c-a d)^3 (a+b x)^3} \]
(18*B^2*d^3*n^2*(a + b*x)^3*Log[a + b*x]^2 + 18*B^2*d^3*n^2*(a + b*x)^3*Lo g[c + d*x]^2 + 6*B*d^3*n*(a + b*x)^3*Log[c + d*x]*(6*A + 11*B*n + 6*B*Log[ (e*(a + b*x)^n)/(c + d*x)^n]) - 6*B*d^3*n*(a + b*x)^3*Log[a + b*x]*(6*A + 11*B*n + 6*B*n*Log[c + d*x] + 6*B*Log[(e*(a + b*x)^n)/(c + d*x)^n]) - (b*c - a*d)*(18*A^2*(b*c - a*d)^2 + 6*A*B*n*(11*a^2*d^2 + a*b*d*(-7*c + 15*d*x ) + b^2*(2*c^2 - 3*c*d*x + 6*d^2*x^2)) + B^2*n^2*(85*a^2*d^2 + a*b*d*(-23* c + 147*d*x) + b^2*(4*c^2 - 15*c*d*x + 66*d^2*x^2)) + 6*B*(6*A*(b*c - a*d) ^2 + B*n*(11*a^2*d^2 + a*b*d*(-7*c + 15*d*x) + b^2*(2*c^2 - 3*c*d*x + 6*d^ 2*x^2)))*Log[(e*(a + b*x)^n)/(c + d*x)^n] + 18*B^2*(b*c - a*d)^2*Log[(e*(a + b*x)^n)/(c + d*x)^n]^2))/(54*b*(b*c - a*d)^3*(a + b*x)^3)
Time = 0.58 (sec) , antiderivative size = 342, normalized size of antiderivative = 0.80, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.121, Rules used = {2973, 2949, 2795, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {\left (B \log \left (e (a+b x)^n (c+d x)^{-n}\right )+A\right )^2}{(a+b x)^4} \, dx\) |
\(\Big \downarrow \) 2973 |
\(\displaystyle \int \frac {\left (B \log \left (e (a+b x)^n (c+d x)^{-n}\right )+A\right )^2}{(a+b x)^4}dx\) |
\(\Big \downarrow \) 2949 |
\(\displaystyle \frac {\int \frac {(c+d x)^4 \left (b-\frac {d (a+b x)}{c+d x}\right )^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{(a+b x)^4}d\frac {a+b x}{c+d x}}{(b c-a d)^3}\) |
\(\Big \downarrow \) 2795 |
\(\displaystyle \frac {\int \left (\frac {b^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2 (c+d x)^4}{(a+b x)^4}-\frac {2 b d \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2 (c+d x)^3}{(a+b x)^3}+\frac {d^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2 (c+d x)^2}{(a+b x)^2}\right )d\frac {a+b x}{c+d x}}{(b c-a d)^3}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {-\frac {b^2 (c+d x)^3 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )^2}{3 (a+b x)^3}-\frac {2 b^2 B n (c+d x)^3 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{9 (a+b x)^3}-\frac {d^2 (c+d x) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )^2}{a+b x}-\frac {2 B d^2 n (c+d x) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{a+b x}+\frac {b d (c+d x)^2 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )^2}{(a+b x)^2}+\frac {b B d n (c+d x)^2 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{(a+b x)^2}-\frac {2 b^2 B^2 n^2 (c+d x)^3}{27 (a+b x)^3}-\frac {2 B^2 d^2 n^2 (c+d x)}{a+b x}+\frac {b B^2 d n^2 (c+d x)^2}{2 (a+b x)^2}}{(b c-a d)^3}\) |
((-2*B^2*d^2*n^2*(c + d*x))/(a + b*x) + (b*B^2*d*n^2*(c + d*x)^2)/(2*(a + b*x)^2) - (2*b^2*B^2*n^2*(c + d*x)^3)/(27*(a + b*x)^3) - (2*B*d^2*n*(c + d *x)*(A + B*Log[e*((a + b*x)/(c + d*x))^n]))/(a + b*x) + (b*B*d*n*(c + d*x) ^2*(A + B*Log[e*((a + b*x)/(c + d*x))^n]))/(a + b*x)^2 - (2*b^2*B*n*(c + d *x)^3*(A + B*Log[e*((a + b*x)/(c + d*x))^n]))/(9*(a + b*x)^3) - (d^2*(c + d*x)*(A + B*Log[e*((a + b*x)/(c + d*x))^n])^2)/(a + b*x) + (b*d*(c + d*x)^ 2*(A + B*Log[e*((a + b*x)/(c + d*x))^n])^2)/(a + b*x)^2 - (b^2*(c + d*x)^3 *(A + B*Log[e*((a + b*x)/(c + d*x))^n])^2)/(3*(a + b*x)^3))/(b*c - a*d)^3
3.2.62.3.1 Defintions of rubi rules used
Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((f_.)*(x_))^(m_.)*((d_) + (e_.)*(x_)^(r_.))^(q_.), x_Symbol] :> With[{u = ExpandIntegrand[(a + b*Log[ c*x^n])^p, (f*x)^m*(d + e*x^r)^q, x]}, Int[u, x] /; SumQ[u]] /; FreeQ[{a, b , c, d, e, f, m, n, p, q, r}, x] && IntegerQ[q] && (GtQ[q, 0] || (IGtQ[p, 0 ] && IntegerQ[m] && IntegerQ[r]))
Int[((A_.) + Log[(e_.)*(((a_.) + (b_.)*(x_))/((c_.) + (d_.)*(x_)))^(n_.)]*( B_.))^(p_.)*((f_.) + (g_.)*(x_))^(m_.), x_Symbol] :> Simp[(b*c - a*d)^(m + 1)*(g/b)^m Subst[Int[x^m*((A + B*Log[e*x^n])^p/(b - d*x)^(m + 2)), x], x, (a + b*x)/(c + d*x)], x] /; FreeQ[{a, b, c, d, e, f, g, A, B, n}, x] && Ne Q[b*c - a*d, 0] && IntegersQ[m, p] && EqQ[b*f - a*g, 0] && (GtQ[p, 0] || Lt Q[m, -1])
Int[((A_.) + Log[(e_.)*(u_)^(n_.)*(v_)^(mn_)]*(B_.))^(p_.)*(w_.), x_Symbol] :> Subst[Int[w*(A + B*Log[e*(u/v)^n])^p, x], e*(u/v)^n, e*(u^n/v^n)] /; Fr eeQ[{e, A, B, n, p}, x] && EqQ[n + mn, 0] && LinearQ[{u, v}, x] && !Intege rQ[n]
Leaf count of result is larger than twice the leaf count of optimal. \(1399\) vs. \(2(419)=838\).
Time = 57.75 (sec) , antiderivative size = 1400, normalized size of antiderivative = 3.28
method | result | size |
parallelrisch | \(\text {Expression too large to display}\) | \(1400\) |
risch | \(\text {Expression too large to display}\) | \(25057\) |
-1/54*(-66*B^2*ln(b*x+a)*x^3*b^7*d^4*n^2+66*B^2*ln(d*x+c)*x^3*b^7*d^4*n^2- 66*B^2*ln(b*x+a)*a^3*b^4*d^4*n^2+66*B^2*ln(d*x+c)*a^3*b^4*d^4*n^2-36*A*B*l n(b*x+a)*x^3*b^7*d^4*n+36*A*B*ln(d*x+c)*x^3*b^7*d^4*n-198*B^2*ln(b*x+a)*x^ 2*a*b^6*d^4*n^2+198*B^2*ln(d*x+c)*x^2*a*b^6*d^4*n^2-198*B^2*ln(b*x+a)*x*a^ 2*b^5*d^4*n^2+198*B^2*ln(d*x+c)*x*a^2*b^5*d^4*n^2-36*A*B*ln(b*x+a)*a^3*b^4 *d^4*n+36*A*B*ln(d*x+c)*a^3*b^4*d^4*n-108*A*B*x*a*b^6*c*d^3*n-66*B^2*x^2*b ^7*c*d^3*n^2-54*B^2*x*ln(e*(b*x+a)^n/((d*x+c)^n))^2*a^2*b^5*d^4+147*B^2*x* a^2*b^5*d^4*n^2+15*B^2*x*b^7*c^2*d^2*n^2-54*B^2*ln(e*(b*x+a)^n/((d*x+c)^n) )^2*a^2*b^5*c*d^3+54*B^2*ln(e*(b*x+a)^n/((d*x+c)^n))^2*a*b^6*c^2*d^2+66*B^ 2*ln(e*(b*x+a)^n/((d*x+c)^n))*a^3*b^4*d^4*n-12*B^2*ln(e*(b*x+a)^n/((d*x+c) ^n))*b^7*c^3*d*n+36*A*B*ln(e*(b*x+a)^n/((d*x+c)^n))*a^3*b^4*d^4-36*A*B*ln( e*(b*x+a)^n/((d*x+c)^n))*b^7*c^3*d-54*B^2*x^2*ln(e*(b*x+a)^n/((d*x+c)^n))^ 2*a*b^6*d^4+66*B^2*x^2*a*b^6*d^4*n^2-108*A*B*ln(b*x+a)*x^2*a*b^6*d^4*n+108 *A*B*ln(d*x+c)*x^2*a*b^6*d^4*n-108*A*B*ln(b*x+a)*x*a^2*b^5*d^4*n+108*A*B*l n(d*x+c)*x*a^2*b^5*d^4*n-18*B^2*x^3*ln(e*(b*x+a)^n/((d*x+c)^n))^2*b^7*d^4- 18*B^2*ln(e*(b*x+a)^n/((d*x+c)^n))^2*b^7*c^3*d+27*B^2*a*b^6*c^2*d^2*n^2+66 *A*B*a^3*b^4*d^4*n-12*A*B*b^7*c^3*d*n-54*A^2*a^2*b^5*c*d^3+54*A^2*a*b^6*c^ 2*d^2+36*B^2*x^2*ln(e*(b*x+a)^n/((d*x+c)^n))*a*b^6*d^4*n-36*B^2*x^2*ln(e*( b*x+a)^n/((d*x+c)^n))*b^7*c*d^3*n+36*A*B*x^2*a*b^6*d^4*n-36*A*B*x^2*b^7*c* d^3*n+90*B^2*x*ln(e*(b*x+a)^n/((d*x+c)^n))*a^2*b^5*d^4*n+18*B^2*x*ln(e*...
Leaf count of result is larger than twice the leaf count of optimal. 1635 vs. \(2 (419) = 838\).
Time = 0.33 (sec) , antiderivative size = 1635, normalized size of antiderivative = 3.83 \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{(a+b x)^4} \, dx=\text {Too large to display} \]
-1/54*(18*A^2*b^3*c^3 - 54*A^2*a*b^2*c^2*d + 54*A^2*a^2*b*c*d^2 - 18*A^2*a ^3*d^3 + (4*B^2*b^3*c^3 - 27*B^2*a*b^2*c^2*d + 108*B^2*a^2*b*c*d^2 - 85*B^ 2*a^3*d^3)*n^2 + 6*(11*(B^2*b^3*c*d^2 - B^2*a*b^2*d^3)*n^2 + 6*(A*B*b^3*c* d^2 - A*B*a*b^2*d^3)*n)*x^2 + 18*(B^2*b^3*d^3*n^2*x^3 + 3*B^2*a*b^2*d^3*n^ 2*x^2 + 3*B^2*a^2*b*d^3*n^2*x + (B^2*b^3*c^3 - 3*B^2*a*b^2*c^2*d + 3*B^2*a ^2*b*c*d^2)*n^2)*log(b*x + a)^2 + 18*(B^2*b^3*d^3*n^2*x^3 + 3*B^2*a*b^2*d^ 3*n^2*x^2 + 3*B^2*a^2*b*d^3*n^2*x + (B^2*b^3*c^3 - 3*B^2*a*b^2*c^2*d + 3*B ^2*a^2*b*c*d^2)*n^2)*log(d*x + c)^2 + 18*(B^2*b^3*c^3 - 3*B^2*a*b^2*c^2*d + 3*B^2*a^2*b*c*d^2 - B^2*a^3*d^3)*log(e)^2 + 6*(2*A*B*b^3*c^3 - 9*A*B*a*b ^2*c^2*d + 18*A*B*a^2*b*c*d^2 - 11*A*B*a^3*d^3)*n - 3*((5*B^2*b^3*c^2*d - 54*B^2*a*b^2*c*d^2 + 49*B^2*a^2*b*d^3)*n^2 + 6*(A*B*b^3*c^2*d - 6*A*B*a*b^ 2*c*d^2 + 5*A*B*a^2*b*d^3)*n)*x + 6*((11*B^2*b^3*d^3*n^2 + 6*A*B*b^3*d^3*n )*x^3 + (2*B^2*b^3*c^3 - 9*B^2*a*b^2*c^2*d + 18*B^2*a^2*b*c*d^2)*n^2 + 3*( 6*A*B*a*b^2*d^3*n + (2*B^2*b^3*c*d^2 + 9*B^2*a*b^2*d^3)*n^2)*x^2 + 6*(A*B* b^3*c^3 - 3*A*B*a*b^2*c^2*d + 3*A*B*a^2*b*c*d^2)*n + 3*(6*A*B*a^2*b*d^3*n - (B^2*b^3*c^2*d - 6*B^2*a*b^2*c*d^2 - 6*B^2*a^2*b*d^3)*n^2)*x + 6*(B^2*b^ 3*d^3*n*x^3 + 3*B^2*a*b^2*d^3*n*x^2 + 3*B^2*a^2*b*d^3*n*x + (B^2*b^3*c^3 - 3*B^2*a*b^2*c^2*d + 3*B^2*a^2*b*c*d^2)*n)*log(e))*log(b*x + a) - 6*((11*B ^2*b^3*d^3*n^2 + 6*A*B*b^3*d^3*n)*x^3 + (2*B^2*b^3*c^3 - 9*B^2*a*b^2*c^2*d + 18*B^2*a^2*b*c*d^2)*n^2 + 3*(6*A*B*a*b^2*d^3*n + (2*B^2*b^3*c*d^2 + ...
Timed out. \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{(a+b x)^4} \, dx=\text {Timed out} \]
Leaf count of result is larger than twice the leaf count of optimal. 1500 vs. \(2 (419) = 838\).
Time = 0.29 (sec) , antiderivative size = 1500, normalized size of antiderivative = 3.51 \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{(a+b x)^4} \, dx=\text {Too large to display} \]
-1/54*B^2*(6*(6*d^3*e*n*log(b*x + a)/(b^4*c^3 - 3*a*b^3*c^2*d + 3*a^2*b^2* c*d^2 - a^3*b*d^3) - 6*d^3*e*n*log(d*x + c)/(b^4*c^3 - 3*a*b^3*c^2*d + 3*a ^2*b^2*c*d^2 - a^3*b*d^3) + (6*b^2*d^2*e*n*x^2 + 2*b^2*c^2*e*n - 7*a*b*c*d *e*n + 11*a^2*d^2*e*n - 3*(b^2*c*d*e*n - 5*a*b*d^2*e*n)*x)/(a^3*b^3*c^2 - 2*a^4*b^2*c*d + a^5*b*d^2 + (b^6*c^2 - 2*a*b^5*c*d + a^2*b^4*d^2)*x^3 + 3* (a*b^5*c^2 - 2*a^2*b^4*c*d + a^3*b^3*d^2)*x^2 + 3*(a^2*b^4*c^2 - 2*a^3*b^3 *c*d + a^4*b^2*d^2)*x))*log((b*x + a)^n*e/(d*x + c)^n)/e + (4*b^3*c^3*e^2* n^2 - 27*a*b^2*c^2*d*e^2*n^2 + 108*a^2*b*c*d^2*e^2*n^2 - 85*a^3*d^3*e^2*n^ 2 + 66*(b^3*c*d^2*e^2*n^2 - a*b^2*d^3*e^2*n^2)*x^2 - 18*(b^3*d^3*e^2*n^2*x ^3 + 3*a*b^2*d^3*e^2*n^2*x^2 + 3*a^2*b*d^3*e^2*n^2*x + a^3*d^3*e^2*n^2)*lo g(b*x + a)^2 - 18*(b^3*d^3*e^2*n^2*x^3 + 3*a*b^2*d^3*e^2*n^2*x^2 + 3*a^2*b *d^3*e^2*n^2*x + a^3*d^3*e^2*n^2)*log(d*x + c)^2 - 3*(5*b^3*c^2*d*e^2*n^2 - 54*a*b^2*c*d^2*e^2*n^2 + 49*a^2*b*d^3*e^2*n^2)*x + 66*(b^3*d^3*e^2*n^2*x ^3 + 3*a*b^2*d^3*e^2*n^2*x^2 + 3*a^2*b*d^3*e^2*n^2*x + a^3*d^3*e^2*n^2)*lo g(b*x + a) - 6*(11*b^3*d^3*e^2*n^2*x^3 + 33*a*b^2*d^3*e^2*n^2*x^2 + 33*a^2 *b*d^3*e^2*n^2*x + 11*a^3*d^3*e^2*n^2 - 6*(b^3*d^3*e^2*n^2*x^3 + 3*a*b^2*d ^3*e^2*n^2*x^2 + 3*a^2*b*d^3*e^2*n^2*x + a^3*d^3*e^2*n^2)*log(b*x + a))*lo g(d*x + c))/((a^3*b^4*c^3 - 3*a^4*b^3*c^2*d + 3*a^5*b^2*c*d^2 - a^6*b*d^3 + (b^7*c^3 - 3*a*b^6*c^2*d + 3*a^2*b^5*c*d^2 - a^3*b^4*d^3)*x^3 + 3*(a*b^6 *c^3 - 3*a^2*b^5*c^2*d + 3*a^3*b^4*c*d^2 - a^4*b^3*d^3)*x^2 + 3*(a^2*b^...
\[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{(a+b x)^4} \, dx=\int { \frac {{\left (B \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right ) + A\right )}^{2}}{{\left (b x + a\right )}^{4}} \,d x } \]
Time = 3.51 (sec) , antiderivative size = 911, normalized size of antiderivative = 2.13 \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{(a+b x)^4} \, dx=\frac {\frac {18\,A^2\,a^2\,d^2-36\,A^2\,a\,b\,c\,d+18\,A^2\,b^2\,c^2+66\,A\,B\,a^2\,d^2\,n-42\,A\,B\,a\,b\,c\,d\,n+12\,A\,B\,b^2\,c^2\,n+85\,B^2\,a^2\,d^2\,n^2-23\,B^2\,a\,b\,c\,d\,n^2+4\,B^2\,b^2\,c^2\,n^2}{6\,\left (a\,d-b\,c\right )}+\frac {x\,\left (-5\,c\,B^2\,b^2\,d\,n^2+49\,a\,B^2\,b\,d^2\,n^2-6\,A\,c\,B\,b^2\,d\,n+30\,A\,a\,B\,b\,d^2\,n\right )}{2\,\left (a\,d-b\,c\right )}+\frac {d\,x^2\,\left (11\,d\,B^2\,b^2\,n^2+6\,A\,d\,B\,b^2\,n\right )}{a\,d-b\,c}}{x^3\,\left (9\,b^5\,c-9\,a\,b^4\,d\right )+x\,\left (27\,a^2\,b^3\,c-27\,a^3\,b^2\,d\right )-x^2\,\left (27\,a^2\,b^3\,d-27\,a\,b^4\,c\right )+9\,a^3\,b^2\,c-9\,a^4\,b\,d}-{\ln \left (\frac {e\,{\left (a+b\,x\right )}^n}{{\left (c+d\,x\right )}^n}\right )}^2\,\left (\frac {B^2}{3\,b\,\left (a^3+3\,a^2\,b\,x+3\,a\,b^2\,x^2+b^3\,x^3\right )}-\frac {B^2\,d^3}{3\,b\,\left (a^3\,d^3-3\,a^2\,b\,c\,d^2+3\,a\,b^2\,c^2\,d-b^3\,c^3\right )}\right )-\ln \left (\frac {e\,{\left (a+b\,x\right )}^n}{{\left (c+d\,x\right )}^n}\right )\,\left (\frac {2\,A\,B}{3\,\left (a^3\,b+3\,a^2\,b^2\,x+3\,a\,b^3\,x^2+b^4\,x^3\right )}+\frac {2\,B^2\,d^3\,\left (a\,\left (\frac {b\,n\,\left (a\,d-b\,c\right )\,\left (3\,a\,d-b\,c\right )}{2\,d^2}+\frac {a\,b\,n\,\left (a\,d-b\,c\right )}{d}\right )+x\,\left (b\,\left (\frac {b\,n\,\left (a\,d-b\,c\right )\,\left (3\,a\,d-b\,c\right )}{2\,d^2}+\frac {a\,b\,n\,\left (a\,d-b\,c\right )}{d}\right )+\frac {2\,a\,b^2\,n\,\left (a\,d-b\,c\right )}{d}+\frac {b^2\,n\,\left (a\,d-b\,c\right )\,\left (3\,a\,d-b\,c\right )}{d^2}\right )+\frac {b\,n\,\left (a\,d-b\,c\right )\,\left (3\,a^2\,d^2-3\,a\,b\,c\,d+b^2\,c^2\right )}{d^3}+\frac {3\,b^3\,n\,x^2\,\left (a\,d-b\,c\right )}{d}\right )}{9\,b\,\left (a^3\,d^3-3\,a^2\,b\,c\,d^2+3\,a\,b^2\,c^2\,d-b^3\,c^3\right )\,\left (a^3\,b+3\,a^2\,b^2\,x+3\,a\,b^3\,x^2+b^4\,x^3\right )}\right )-\frac {B\,d^3\,n\,\mathrm {atan}\left (\frac {B\,d^3\,n\,\left (6\,A+11\,B\,n\right )\,\left (\frac {a^3\,b\,d^3-a^2\,b^2\,c\,d^2-a\,b^3\,c^2\,d+b^4\,c^3}{a^2\,b\,d^2-2\,a\,b^2\,c\,d+b^3\,c^2}+2\,b\,d\,x\right )\,\left (a^2\,b\,d^2-2\,a\,b^2\,c\,d+b^3\,c^2\right )\,1{}\mathrm {i}}{b\,\left (11\,B^2\,d^3\,n^2+6\,A\,B\,d^3\,n\right )\,{\left (a\,d-b\,c\right )}^3}\right )\,\left (6\,A+11\,B\,n\right )\,2{}\mathrm {i}}{9\,b\,{\left (a\,d-b\,c\right )}^3} \]
((18*A^2*a^2*d^2 + 18*A^2*b^2*c^2 + 85*B^2*a^2*d^2*n^2 + 4*B^2*b^2*c^2*n^2 - 36*A^2*a*b*c*d + 66*A*B*a^2*d^2*n + 12*A*B*b^2*c^2*n - 23*B^2*a*b*c*d*n ^2 - 42*A*B*a*b*c*d*n)/(6*(a*d - b*c)) + (x*(49*B^2*a*b*d^2*n^2 - 5*B^2*b^ 2*c*d*n^2 + 30*A*B*a*b*d^2*n - 6*A*B*b^2*c*d*n))/(2*(a*d - b*c)) + (d*x^2* (11*B^2*b^2*d*n^2 + 6*A*B*b^2*d*n))/(a*d - b*c))/(x^3*(9*b^5*c - 9*a*b^4*d ) + x*(27*a^2*b^3*c - 27*a^3*b^2*d) - x^2*(27*a^2*b^3*d - 27*a*b^4*c) + 9* a^3*b^2*c - 9*a^4*b*d) - log((e*(a + b*x)^n)/(c + d*x)^n)^2*(B^2/(3*b*(a^3 + b^3*x^3 + 3*a*b^2*x^2 + 3*a^2*b*x)) - (B^2*d^3)/(3*b*(a^3*d^3 - b^3*c^3 + 3*a*b^2*c^2*d - 3*a^2*b*c*d^2))) - log((e*(a + b*x)^n)/(c + d*x)^n)*((2 *A*B)/(3*(a^3*b + b^4*x^3 + 3*a^2*b^2*x + 3*a*b^3*x^2)) + (2*B^2*d^3*(a*(( b*n*(a*d - b*c)*(3*a*d - b*c))/(2*d^2) + (a*b*n*(a*d - b*c))/d) + x*(b*((b *n*(a*d - b*c)*(3*a*d - b*c))/(2*d^2) + (a*b*n*(a*d - b*c))/d) + (2*a*b^2* n*(a*d - b*c))/d + (b^2*n*(a*d - b*c)*(3*a*d - b*c))/d^2) + (b*n*(a*d - b* c)*(3*a^2*d^2 + b^2*c^2 - 3*a*b*c*d))/d^3 + (3*b^3*n*x^2*(a*d - b*c))/d))/ (9*b*(a^3*d^3 - b^3*c^3 + 3*a*b^2*c^2*d - 3*a^2*b*c*d^2)*(a^3*b + b^4*x^3 + 3*a^2*b^2*x + 3*a*b^3*x^2))) - (B*d^3*n*atan((B*d^3*n*(6*A + 11*B*n)*((b ^4*c^3 + a^3*b*d^3 - a^2*b^2*c*d^2 - a*b^3*c^2*d)/(b^3*c^2 + a^2*b*d^2 - 2 *a*b^2*c*d) + 2*b*d*x)*(b^3*c^2 + a^2*b*d^2 - 2*a*b^2*c*d)*1i)/(b*(11*B^2* d^3*n^2 + 6*A*B*d^3*n)*(a*d - b*c)^3))*(6*A + 11*B*n)*2i)/(9*b*(a*d - b*c) ^3)